﻿//using System;
//using System.Collections.Generic;
//using System.Collections.Specialized;
//using System.ComponentModel;
//using System.Linq;
//using System.Text;
//using System.Web;
//using System.Windows.Forms;
//TODO:Code to be added
//namespace zielonka.co.uk.extensions.system.web.ui.webcontrols
//{
//    //Description:	When a silverlight MediaElement finishes playing, it does not rewind automatically. This extension method sets the MediaElement position at Zero and starts playing.
//    /*
//        ListBox1.AddToEnd( "foo" );
//        ListBox1.AddToEnd( "bar" );
//     */

//    public static partial class MediaElementExtensions
//    {
//        public static void Rewind(this MediaElement mediaElement)
//        {
//            if (mediaElement.CurrentState != MediaElementState.Stopped)
//                mediaElement.Stop();
//            mediaElement.Position = TimeSpan.Zero;
//        }
//        public static void RewindAndPlay(this MediaElement mediaElement)
//        {
//            mediaElement.Rewind();
//            mediaElement.Play();
//        }
//    }
//}
